package com.erp.service;

import org.springframework.messaging.Message;

import java.util.Map;

public interface RocketMQTemplateProducer {

    void send(String topicName, String data);

    void send(String topicName, String data, Map<String, Object> headers);

    void send(String topicName, String tags, String data);

    void send(String topicName, String tags, String data, Map<String, Object> headers);

    void send(String topicName, Message<?> message);

    void send(String topicName, Message<?> message, Map<String, Object> headers);

    void send(String topicName, String tags, Message<?> message);

    void send(String topicName, String tags, Message<?> message, Map<String, Object> headers);

    void send(String topicName, Message<?> message, int delayLevel);

    void send(String topicName, Message<?> message, Map<String, Object> headers, int delayLevel);

    void send(String topicName, String tags, Message<?> message, int delayLevel);

    void send(String topicName, String tags, Message<?> message, Map<String, Object> headers, int delayLevel);

    /**
     * 发送顺序消息
     *
     * @param topicName
     * @param tags
     * @param message
     * @param hashKey
     * @param headers
     * @param delayLevel
     */
    void send(String topicName, String tags, Message<?> message, String hashKey, Map<String, Object> headers, int delayLevel);
}
